home *** CD-ROM | disk | FTP | other *** search
/ MacWorld 1997 August / Macworld (1997-08).dmg / Serious Demos / Crimson Demo / Crimson Demos / Customer File / Common next >
Text File  |  1997-06-17  |  516b  |  25 lines

  1. Procedure Read_File() Public
  2. Local CurrRec As Integer
  3.  
  4. Local CustStruct As Structure
  5.         Local Cust_no As Integer
  6.         Local Cust_name As String [30]
  7.         Local Cust_addr As String [255]
  8.         Local Cust_phone As String [16]
  9.         Local Cust_fax As String [16]
  10.         Local Cust_email As String [30]
  11.         Local Cust_location As Integer
  12. Endstruct
  13.  
  14.         CurrRec=0
  15.         Repeat
  16.                 Inc CurrRec
  17.                 Get #1,CurrRec,CustStruct
  18.                 If ERR
  19.                         NextFreeRec=CurrRec
  20.                 Else
  21.                         LocateForm.LBox.InsertRow(CurrRec,Cust_name)
  22.                 Endif
  23.         Until ERR
  24. Return
  25.